<div class="information">
	<?php echo $count?>
	records have sucessfully added into database.
</div>

<?php 
if (sizeof($error) > 0){
	echo '<div class="errorTitle">'.sizeof($error).' requests are fail to approve</div>';
	echo '<div class="errorTable">';
	echo '<table>';
	echo '<tr>';
	echo '<td> ID </td>';
	echo '<td> Item </td>';
	echo '<td> Barcode</td>';
	echo '<td>Request Amount</td>';
	echo '<td> Reason </td>';
	echo '</tr>';
	foreach($error as $request){
		echo '<tr>';
		echo '<td>'.$request->request_id.'</td>';
		echo '<td>'.$request->item_name.'</td>';
		echo '<td>'.$request->item_barcode.'</td>';
		echo '<td>'.$request->request_amount.'</td>';
		echo '<td>'.$request->reason.'</td>';
		echo '</tr>';
	}
	echo '</table>';
	echo '</div>';
}
?>